package com.lmq.prototype.Demo01;

import java.util.Date;

//客户端
public class Bili {
    public static void main(String[] args) throws CloneNotSupportedException {
        //原型对象
        Date date = new Date();
        Video v1 = new Video("mm视频",date);
        Video v2 = (Video) v1.clone();
        System.out.println("v1=>"+v1);

        System.out.println("v2=>"+v2);


        System.out.println("=====================");
        date.setTime(22111234);
        System.out.println("v1=>"+v1);

        System.out.println("v2=>"+v2);
//        System.out.println("v1=>hash:"+v1.hashCode());

        //v1克隆v2


//        System.out.println("v2=>hash:"+v2.hashCode());
//        v2.setName("clonedmm视频");
//        System.out.println(v2);


    }



}
